﻿using AutoCompleteBoxWPF.Services;
using System.Windows;

namespace AutoCompleteBoxWPF
{
    public partial class MainWindow : Window
    {
        private readonly ApplicationService _applicationService = new ApplicationService();

        public MainWindow()
        {
            Loaded += MainWindow_Loaded;

            InitializeComponent();
        }

        private void MainWindow_Loaded(object sender, RoutedEventArgs e)
        {
            this.AutoCompleteBox.ItemsSource = this._applicationService.ReadAll();
        }
    }
}